/**
 * Description: MaintainRepotTypeAction.java
 * Copyright (c) 2008-2009  Neo. 
 * All Rights Reserved.
 * @version 1.0  Apr 9, 2009 10:20:26 PM 李萌（neolimeng@gmail.com）created
 */
package org.paradise.dms.web.action.maintainreport;

import java.util.List;

import net.sf.json.JSONArray;

import org.apache.log4j.Logger;
import org.directwebremoting.annotations.RemoteProxy;
import org.paradise.dms.pojo.MaintainReportType;
import org.paradise.dms.services.MaintainReportTypeService;
import org.paradise.dms.web.action.DMSBaseAction;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.beans.factory.annotation.Qualifier;
import org.springframework.stereotype.Service;

/**
 * Description: Copyright (c) 2008-2009 Neo. All Rights Reserved.
 * 
 * @version 1.0 Apr 9, 2009 10:20:26 PM 李萌（neolimeng@gmail.com）created
 */
@RemoteProxy(name = "maintainReportTypeAction")
@Service
public class MaintainRepotTypeAction extends DMSBaseAction {
	/**
	 * 
	 */
	private static final long serialVersionUID = 8998668489248086266L;

	@SuppressWarnings("unused")
	private static Logger log = Logger.getLogger(MaintainRepotTypeAction.class);

	@Autowired
	@Qualifier("maintainReportTypeServiceImpl")
	private MaintainReportTypeService maintainReportTypeService;
	private MaintainReportType mrt;
	private List<MaintainReportType> lmrt;

	public JSONArray getAllMaintainRepotType() {
		lmrt = this.maintainReportTypeService.getAllMaintainReportType();
		if (lmrt != null && lmrt.size() > 0) {
			JSONArray jsonarray = JSONArray.fromObject(lmrt);
			return jsonarray;
		}
		return null;
	}

	public MaintainReportTypeService getMaintainReportTypeService() {
		return maintainReportTypeService;
	}

	public void setMaintainReportTypeService(MaintainReportTypeService maintainReportTypeService) {
		this.maintainReportTypeService = maintainReportTypeService;
	}

	public MaintainReportType getMrt() {
		return mrt;
	}

	public void setMrt(MaintainReportType mrt) {
		this.mrt = mrt;
	}

	public List<MaintainReportType> getLmrt() {
		return lmrt;
	}

	public void setLmrt(List<MaintainReportType> lmrt) {
		this.lmrt = lmrt;
	}
}
